package com.bestcem.xm.label.grpc.service.param.labelgroup;

import com.bestcem.xm.common.core.constant.RegTypes;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

import static com.bestcem.xm.label.constant.Constants.TAG_GROUP_NAME_MAX_LEN;

/**
 * @author dc.wang <dc.wang@idiaoyan.com>
 * @version V1.0
 * @description 新标签组名DTO
 * @date 2021/6/23
 */
@Getter
@Setter
@ToString
public class UpdateLabelGroupNameParam {

    @NotBlank(message = "标签组ID为空！")
    @Pattern(regexp = RegTypes.OBJECT_ID, message = "标签组ID异常！")
    private String labelGroupId;

    @NotBlank(message = "企业ID为空！")
    @Pattern(regexp = RegTypes.OBJECT_ID, message = "企业ID异常！")
    private String orgId;

    @NotBlank(message = "标签组名不能为空！")
    @Size(max = TAG_GROUP_NAME_MAX_LEN, message = "标签组名长度不能超过30！")
    private String name;

}
